Knockout groups are used to create graphical effects, such as see-through text, in digital media. Graphical objects that are members of a knockout group are rendered such that the appearance of objects in the background that are overlapped by the objects in the knockout group is obscured (or knocked-out). In contrast to a transparency compositing model, where partially transparent objects permit visibility of background objects, objects in a knockout group do not permit visibility of objects in the background. By definition, a knockout object that completely covers a pixel obscures all objects in the background of the same pixel. However, if a knockout object partially covers a pixel, then the object only partially knocks-out background objects in the same pixel. This means, for example, that when properly rendered, a knockout object covering 30% of a pixel should only contribute to 30% of the pixel's color. The remaining 70% of the pixel's color should come from objects in the background. However, the actual amount of color from the object and the background depends on the rendering techniques employed.
For example, some existing techniques that are implemented in GPUs for rendering knockout groups rely on MSAA (multi-sampled anti-aliasing) for their functionality. With MSAA, each pixel on the screen is broken down into multiple sub-pixels (typically eight sub-pixels). The knock-out resolution is therefore limited to the number of such sub-pixels. In other words, if a sub-pixel is partially covered by a knock-out object, then the sub-pixel is treated as fully covered and all objects underneath the sub-pixel are knocked-out. The sub-pixels that are not covered by a knockout object continue showing colors from objects underneath. Increasing the number of sub-pixels under MSAA improves the resolution, but at the expense of increased memory usage and processing time.
Some existing multi-sampling techniques also use a depth buffer to maintain Z-ordering among objects in knockout groups. Maintaining Z-order supports a knockout requirement that every object inside a knockout group composites with the group's initial backdrop rather than the objects underneath. By maintaining Z-order, such knockout techniques on a GPU keep track of pixel coverage of objects and knockout groups and allow objects and sub-groups within a knockout group to composite correctly. However, using multi-sampling and a depth buffer has performance and memory implications making these techniques inefficient when rendering complicated artwork. The ill-effects of performance and memory are more pronounced while rendering content in CMYK color space which inherently requires more memory than RGB. Therefore, there is a need for improved techniques for GPU rendering of knockout groups.